3.477 \(\int \frac{i-\tan (e+f x)}{\sqrt [3]{c+d \tan (e+f x)}} \, dx\)

Optimal. Leaf size=148 \[ -\frac{\sqrt{3} \tan ^{-1}\left (\frac{1+\frac{2 \sqrt [3]{c+d \tan (e+f x)}}{\sqrt [3]{c-i d}}}{\sqrt{3}}\right )}{f \sqrt [3]{c-i d}}-\frac{3 \log \left (-\sqrt [3]{c+d \tan (e+f x)}+\sqrt [3]{c-i d}\right )}{2 f \sqrt [3]{c-i d}}-\frac{\log (\cos (e+f x))}{2 f \sqrt [3]{c-i d}}-\frac{i x}{2 \sqrt [3]{c-i d}} \]

[Out]

((-I/2)*x)/(c - I*d)^(1/3) - (Sqrt[3]*ArcTan[(1 + (2*(c + d*Tan[e + f*x])^(1/3))/(c - I*d)^(1/3))/Sqrt[3]])/((
c - I*d)^(1/3)*f) - Log[Cos[e + f*x]]/(2*(c - I*d)^(1/3)*f) - (3*Log[(c - I*d)^(1/3) - (c + d*Tan[e + f*x])^(1
/3)])/(2*(c - I*d)^(1/3)*f)

________________________________________________________________________________________

Rubi [A]  time = 0.125532, antiderivative size = 148, normalized size of antiderivative = 1., number of steps used = 5, number of rules used = 5, integrand size = 27, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.185, Rules used = {3537, 55, 617, 204, 31} \[ -\frac{\sqrt{3} \tan ^{-1}\left (\frac{1+\frac{2 \sqrt [3]{c+d \tan (e+f x)}}{\sqrt [3]{c-i d}}}{\sqrt{3}}\right )}{f \sqrt [3]{c-i d}}-\frac{3 \log \left (-\sqrt [3]{c+d \tan (e+f x)}+\sqrt [3]{c-i d}\right )}{2 f \sqrt [3]{c-i d}}-\frac{\log (\cos (e+f x))}{2 f \sqrt [3]{c-i d}}-\frac{i x}{2 \sqrt [3]{c-i d}} \]

Antiderivative was successfully verified.

[In]

Int[(I - Tan[e + f*x])/(c + d*Tan[e + f*x])^(1/3),x]

[Out]

((-I/2)*x)/(c - I*d)^(1/3) - (Sqrt[3]*ArcTan[(1 + (2*(c + d*Tan[e + f*x])^(1/3))/(c - I*d)^(1/3))/Sqrt[3]])/((
c - I*d)^(1/3)*f) - Log[Cos[e + f*x]]/(2*(c - I*d)^(1/3)*f) - (3*Log[(c - I*d)^(1/3) - (c + d*Tan[e + f*x])^(1
/3)])/(2*(c - I*d)^(1/3)*f)

Rule 3537

Int[((a_.) + (b_.)*tan[(e_.) + (f_.)*(x_)])^(m_)*((c_) + (d_.)*tan[(e_.) + (f_.)*(x_)]), x_Symbol] :> Dist[(c*
d)/f, Subst[Int[(a + (b*x)/d)^m/(d^2 + c*x), x], x, d*Tan[e + f*x]], x] /; FreeQ[{a, b, c, d, e, f, m}, x] &&
NeQ[b*c - a*d, 0] && NeQ[a^2 + b^2, 0] && EqQ[c^2 + d^2, 0]

Rule 55

Int[1/(((a_.) + (b_.)*(x_))*((c_.) + (d_.)*(x_))^(1/3)), x_Symbol] :> With[{q = Rt[(b*c - a*d)/b, 3]}, -Simp[L
og[RemoveContent[a + b*x, x]]/(2*b*q), x] + (Dist[3/(2*b), Subst[Int[1/(q^2 + q*x + x^2), x], x, (c + d*x)^(1/
3)], x] - Dist[3/(2*b*q), Subst[Int[1/(q - x), x], x, (c + d*x)^(1/3)], x])] /; FreeQ[{a, b, c, d}, x] && PosQ
[(b*c - a*d)/b]

Rule 617

Int[((a_) + (b_.)*(x_) + (c_.)*(x_)^2)^(-1), x_Symbol] :> With[{q = 1 - 4*Simplify[(a*c)/b^2]}, Dist[-2/b, Sub
st[Int[1/(q - x^2), x], x, 1 + (2*c*x)/b], x] /; RationalQ[q] && (EqQ[q^2, 1] ||  !RationalQ[b^2 - 4*a*c])] /;
 FreeQ[{a, b, c}, x] && NeQ[b^2 - 4*a*c, 0]

Rule 204

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> -Simp[ArcTan[(Rt[-b, 2]*x)/Rt[-a, 2]]/(Rt[-a, 2]*Rt[-b, 2]), x] /
; FreeQ[{a, b}, x] && PosQ[a/b] && (LtQ[a, 0] || LtQ[b, 0])

Rule 31

Int[((a_) + (b_.)*(x_))^(-1), x_Symbol] :> Simp[Log[RemoveContent[a + b*x, x]]/b, x] /; FreeQ[{a, b}, x]

Rubi steps

\begin{align*} \int \frac{i-\tan (e+f x)}{\sqrt [3]{c+d \tan (e+f x)}} \, dx &=-\frac{i \operatorname{Subst}\left (\int \frac{1}{(1+i x) \sqrt [3]{c-d x}} \, dx,x,-\tan (e+f x)\right )}{f}\\ &=-\frac{i x}{2 \sqrt [3]{c-i d}}-\frac{\log (\cos (e+f x))}{2 \sqrt [3]{c-i d} f}-\frac{3 \operatorname{Subst}\left (\int \frac{1}{(c-i d)^{2/3}+\sqrt [3]{c-i d} x+x^2} \, dx,x,\sqrt [3]{c+d \tan (e+f x)}\right )}{2 f}+\frac{3 \operatorname{Subst}\left (\int \frac{1}{\sqrt [3]{c-i d}-x} \, dx,x,\sqrt [3]{c+d \tan (e+f x)}\right )}{2 \sqrt [3]{c-i d} f}\\ &=-\frac{i x}{2 \sqrt [3]{c-i d}}-\frac{\log (\cos (e+f x))}{2 \sqrt [3]{c-i d} f}-\frac{3 \log \left (\sqrt [3]{c-i d}-\sqrt [3]{c+d \tan (e+f x)}\right )}{2 \sqrt [3]{c-i d} f}+\frac{3 \operatorname{Subst}\left (\int \frac{1}{-3-x^2} \, dx,x,1+\frac{2 \sqrt [3]{c+d \tan (e+f x)}}{\sqrt [3]{c-i d}}\right )}{\sqrt [3]{c-i d} f}\\ &=-\frac{i x}{2 \sqrt [3]{c-i d}}-\frac{\sqrt{3} \tan ^{-1}\left (\frac{1+\frac{2 \sqrt [3]{c+d \tan (e+f x)}}{\sqrt [3]{c-i d}}}{\sqrt{3}}\right )}{\sqrt [3]{c-i d} f}-\frac{\log (\cos (e+f x))}{2 \sqrt [3]{c-i d} f}-\frac{3 \log \left (\sqrt [3]{c-i d}-\sqrt [3]{c+d \tan (e+f x)}\right )}{2 \sqrt [3]{c-i d} f}\\ \end{align*}

Mathematica [C]  time = 1.72742, size = 109, normalized size = 0.74 \[ \frac{3 \left (c-\frac{i d \left (-1+e^{2 i (e+f x)}\right )}{1+e^{2 i (e+f x)}}\right )^{2/3} \text{Hypergeometric2F1}\left (\frac{2}{3},1,\frac{5}{3},\frac{i c+\frac{d \left (-1+e^{2 i (e+f x)}\right )}{1+e^{2 i (e+f x)}}}{d+i c}\right )}{2 f (c-i d)} \]

Antiderivative was successfully verified.

[In]

Integrate[(I - Tan[e + f*x])/(c + d*Tan[e + f*x])^(1/3),x]

[Out]

(3*(c - (I*d*(-1 + E^((2*I)*(e + f*x))))/(1 + E^((2*I)*(e + f*x))))^(2/3)*Hypergeometric2F1[2/3, 1, 5/3, (I*c
+ (d*(-1 + E^((2*I)*(e + f*x))))/(1 + E^((2*I)*(e + f*x))))/(I*c + d)])/(2*(c - I*d)*f)

________________________________________________________________________________________

Maple [C]  time = 0.086, size = 42, normalized size = 0.3 \begin{align*} -{\frac{1}{f}\sum _{{\it \_R}={\it RootOf} \left ({{\it \_Z}}^{3}+id-c \right ) }{\frac{1}{{\it \_R}}\ln \left ( \sqrt [3]{c+d\tan \left ( fx+e \right ) }-{\it \_R} \right ) }} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((-tan(f*x+e)+I)/(c+d*tan(f*x+e))^(1/3),x)

[Out]

-1/f*sum(1/_R*ln((c+d*tan(f*x+e))^(1/3)-_R),_R=RootOf(_Z^3+I*d-c))

________________________________________________________________________________________

Maxima [F]  time = 0., size = 0, normalized size = 0. \begin{align*} -\int \frac{\tan \left (f x + e\right ) - i}{{\left (d \tan \left (f x + e\right ) + c\right )}^{\frac{1}{3}}}\,{d x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-tan(f*x+e)+I)/(c+d*tan(f*x+e))^(1/3),x, algorithm="maxima")

[Out]

-integrate((tan(f*x + e) - I)/(d*tan(f*x + e) + c)^(1/3), x)

________________________________________________________________________________________

Fricas [B]  time = 2.18713, size = 757, normalized size = 5.11 \begin{align*} \frac{1}{2} \,{\left (i \, \sqrt{3} - 1\right )} \left (-\frac{i}{{\left (i \, c + d\right )} f^{3}}\right )^{\frac{1}{3}} \log \left (\frac{1}{2} \,{\left (\sqrt{3}{\left (i \, c + d\right )} f^{2} +{\left (c - i \, d\right )} f^{2}\right )} \left (-\frac{i}{{\left (i \, c + d\right )} f^{3}}\right )^{\frac{2}{3}} + \left (\frac{{\left (c - i \, d\right )} e^{\left (2 i \, f x + 2 i \, e\right )} + c + i \, d}{e^{\left (2 i \, f x + 2 i \, e\right )} + 1}\right )^{\frac{1}{3}}\right ) + \frac{1}{2} \,{\left (-i \, \sqrt{3} - 1\right )} \left (-\frac{i}{{\left (i \, c + d\right )} f^{3}}\right )^{\frac{1}{3}} \log \left (\frac{1}{2} \,{\left (\sqrt{3}{\left (-i \, c - d\right )} f^{2} +{\left (c - i \, d\right )} f^{2}\right )} \left (-\frac{i}{{\left (i \, c + d\right )} f^{3}}\right )^{\frac{2}{3}} + \left (\frac{{\left (c - i \, d\right )} e^{\left (2 i \, f x + 2 i \, e\right )} + c + i \, d}{e^{\left (2 i \, f x + 2 i \, e\right )} + 1}\right )^{\frac{1}{3}}\right ) + \left (-\frac{i}{{\left (i \, c + d\right )} f^{3}}\right )^{\frac{1}{3}} \log \left (-{\left (c - i \, d\right )} f^{2} \left (-\frac{i}{{\left (i \, c + d\right )} f^{3}}\right )^{\frac{2}{3}} + \left (\frac{{\left (c - i \, d\right )} e^{\left (2 i \, f x + 2 i \, e\right )} + c + i \, d}{e^{\left (2 i \, f x + 2 i \, e\right )} + 1}\right )^{\frac{1}{3}}\right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-tan(f*x+e)+I)/(c+d*tan(f*x+e))^(1/3),x, algorithm="fricas")

[Out]

1/2*(I*sqrt(3) - 1)*(-I/((I*c + d)*f^3))^(1/3)*log(1/2*(sqrt(3)*(I*c + d)*f^2 + (c - I*d)*f^2)*(-I/((I*c + d)*
f^3))^(2/3) + (((c - I*d)*e^(2*I*f*x + 2*I*e) + c + I*d)/(e^(2*I*f*x + 2*I*e) + 1))^(1/3)) + 1/2*(-I*sqrt(3) -
 1)*(-I/((I*c + d)*f^3))^(1/3)*log(1/2*(sqrt(3)*(-I*c - d)*f^2 + (c - I*d)*f^2)*(-I/((I*c + d)*f^3))^(2/3) + (
((c - I*d)*e^(2*I*f*x + 2*I*e) + c + I*d)/(e^(2*I*f*x + 2*I*e) + 1))^(1/3)) + (-I/((I*c + d)*f^3))^(1/3)*log(-
(c - I*d)*f^2*(-I/((I*c + d)*f^3))^(2/3) + (((c - I*d)*e^(2*I*f*x + 2*I*e) + c + I*d)/(e^(2*I*f*x + 2*I*e) + 1
))^(1/3))

________________________________________________________________________________________

Sympy [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{- \tan{\left (e + f x \right )} + i}{\sqrt [3]{c + d \tan{\left (e + f x \right )}}}\, dx \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((I-tan(f*x+e))/(c+d*tan(f*x+e))**(1/3),x)

[Out]

Integral((-tan(e + f*x) + I)/(c + d*tan(e + f*x))**(1/3), x)

________________________________________________________________________________________

Giac [B]  time = 1.57748, size = 1229, normalized size = 8.3 \begin{align*} \text{result too large to display} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-tan(f*x+e)+I)/(c+d*tan(f*x+e))^(1/3),x, algorithm="giac")

[Out]

-(c - I*d)^(2/3)*log((d*tan(f*x + e) + c)^(1/3) - (c - I*d)^(1/3))/(c*f - I*d*f) - (sqrt(3)*(c^2 + d^2)^(1/3)*
c*cos(1/6*pi*sgn(c)*sgn(d) - 1/6*pi*sgn(d) - 1/3*arctan(d/c))^2 - sqrt(3)*(c^2 + d^2)^(1/3)*c*sin(1/6*pi*sgn(c
)*sgn(d) - 1/6*pi*sgn(d) - 1/3*arctan(d/c))^2 + 2*(c^2 + d^2)^(1/3)*c*cos(1/6*pi*sgn(c)*sgn(d) - 1/6*pi*sgn(d)
 - 1/3*arctan(d/c))*sin(1/6*pi*sgn(c)*sgn(d) - 1/6*pi*sgn(d) - 1/3*arctan(d/c)))*arctan(1/3*sqrt(3)*(2*(d*tan(
f*x + e) + c)^(1/3) + (c - I*d)^(1/3))/(c - I*d)^(1/3))/((c^2 + d^2)*f) - I*(sqrt(3)*(c^2 + d^2)^(1/3)*d*cos(1
/6*pi*sgn(c)*sgn(d) - 1/6*pi*sgn(d) - 1/3*arctan(d/c))^2 - sqrt(3)*(c^2 + d^2)^(1/3)*d*sin(1/6*pi*sgn(c)*sgn(d
) - 1/6*pi*sgn(d) - 1/3*arctan(d/c))^2 + 2*(c^2 + d^2)^(1/3)*d*cos(1/6*pi*sgn(c)*sgn(d) - 1/6*pi*sgn(d) - 1/3*
arctan(d/c))*sin(1/6*pi*sgn(c)*sgn(d) - 1/6*pi*sgn(d) - 1/3*arctan(d/c)))*arctan(1/3*sqrt(3)*(2*(d*tan(f*x + e
) + c)^(1/3) + (c - I*d)^(1/3))/(c - I*d)^(1/3))/((c^2 + d^2)*f) - 1/2*(2*sqrt(3)*(c^2 + d^2)^(1/3)*c*cos(1/6*
pi*sgn(c)*sgn(d) - 1/6*pi*sgn(d) - 1/3*arctan(d/c))*sin(1/6*pi*sgn(c)*sgn(d) - 1/6*pi*sgn(d) - 1/3*arctan(d/c)
) - (c^2 + d^2)^(1/3)*c*cos(1/6*pi*sgn(c)*sgn(d) - 1/6*pi*sgn(d) - 1/3*arctan(d/c))^2 + (c^2 + d^2)^(1/3)*c*si
n(1/6*pi*sgn(c)*sgn(d) - 1/6*pi*sgn(d) - 1/3*arctan(d/c))^2)*log((c^2 + d^2)^(1/3)*cos(1/6*pi*sgn(c)*sgn(d) -
1/6*pi*sgn(d) - 1/3*arctan(d/c))^2 + (c^2 + d^2)^(1/3)*sin(1/6*pi*sgn(c)*sgn(d) - 1/6*pi*sgn(d) - 1/3*arctan(d
/c))^2 + (d*tan(f*x + e) + c)^(2/3) + (d*tan(f*x + e) + c)^(1/3)*(c - I*d)^(1/3))/((c^2 + d^2)*f) - 1/2*I*(2*s
qrt(3)*(c^2 + d^2)^(1/3)*d*cos(1/6*pi*sgn(c)*sgn(d) - 1/6*pi*sgn(d) - 1/3*arctan(d/c))*sin(1/6*pi*sgn(c)*sgn(d
) - 1/6*pi*sgn(d) - 1/3*arctan(d/c)) - (c^2 + d^2)^(1/3)*d*cos(1/6*pi*sgn(c)*sgn(d) - 1/6*pi*sgn(d) - 1/3*arct
an(d/c))^2 + (c^2 + d^2)^(1/3)*d*sin(1/6*pi*sgn(c)*sgn(d) - 1/6*pi*sgn(d) - 1/3*arctan(d/c))^2)*log((c^2 + d^2
)^(1/3)*cos(1/6*pi*sgn(c)*sgn(d) - 1/6*pi*sgn(d) - 1/3*arctan(d/c))^2 + (c^2 + d^2)^(1/3)*sin(1/6*pi*sgn(c)*sg
n(d) - 1/6*pi*sgn(d) - 1/3*arctan(d/c))^2 + (d*tan(f*x + e) + c)^(2/3) + (d*tan(f*x + e) + c)^(1/3)*(c - I*d)^
(1/3))/((c^2 + d^2)*f)